package com.lms.desiginmode.builder.endpointbuilder;

import com.lms.desiginmode.builder.Info;
import com.lms.desiginmode.builder.endpointbuilder.Endpoint;
import com.lms.desiginmode.builder.endpointbuilder.EndpointBuilder;

/**
 * @Author: 李孟帅
 * @CreateTime: 2020-12-12 16:41
 * @Description:
 */
public class Director {
    EndpointBuilder endpointBuilder;

    public Director(EndpointBuilder endpointBuilder){
        this.endpointBuilder=endpointBuilder;
    }

    public Info build(){
        Endpoint build = endpointBuilder.build();
        Info info = new Info();
        info.setEndpoint(build);
        return info;
    }
}
